<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <div></div>
</body>
</html>



<script>
    function get(){
        let jiang = +new Date('2022/11/03 24:00:00')
        let xian = +new Date()
        let cha = jiang - xian
        let day = parseInt(cha/1000/60/60/24)
        day = day>=10?day:'0'+day
        let hours = parseInt(cha/1000/60/60%24)
        hours = hours>=10?hours:'0'+hours
        let fen = parseInt(cha/1000/60%60)
        fen = fen>=10?fen:'0'+fen
        let miao = parseInt(cha/1000%60)
        miao = miao>=10?miao:'0'+miao
        var div = document.querySelector('div')
        div.innerHTML = day +'天' +hours +'时' +fen +'分' + miao+'秒'

    }
    get()

    setInterval(get,1000)
</script>

<style>
    div{
        background-color: pink;
        width: 400px;
        text-align: center;
        margin: auto;
        font-size: 40px;
    }
</style>